package net.hn.hnms.biz.common.activiti.aop;

import net.hn.hnms.biz.common.activiti.utils.SecurityUtil;
import org.aspectj.lang.annotation.Aspect;
import org.aspectj.lang.annotation.Before;
import org.aspectj.lang.annotation.Pointcut;
import org.springframework.stereotype.Component;

import javax.annotation.Resource;

/**
 * Created on 2022/8/9.
 * @author ly
 * @desc: 安全配置
 */
@Aspect
@Component
public class SecurityAop {

    @Resource
    private SecurityUtil securityUtil;

    @Pointcut("execution(* net.hn.hnms.biz.common.activiti.service.impl.*.*(..))")
    public void pointcut() {

    }

    @Before("pointcut()")
    public void beginTransaction() {
        securityUtil.logInAs("jack");
    }

}
